﻿/**
 * ajax提交添加网站配置的信息
 */
$(function () {
    $('#configSubmit').click(function () {
        var postdata = "id=" + $.trim($("#configId").val()) +"&sitename=" + $.trim($("#sitename").val()) + "&siteurl=" + $.trim($("#siteurl").val())
            + "&isopen=" + $.trim( $("input[name='isopen']").val())+"&closeword=" + $.trim($("#closeword").val())+"&copyright=" + $.trim( $("input[name='copyright']").val());
        $.post("/admin/updateConfig", postdata, function (data) {
            if (data.code == 200) {
                alert("提交成功");
            } else {
                alert("提交失败");
            }
        }, "json");
    });
});
